package cn.wolfcode.trip.base.service.impl;

import cn.wolfcode.trip.base.domain.Point;
import cn.wolfcode.trip.base.mapper.PointMapper;
import cn.wolfcode.trip.base.service.IPointService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class PointServiceImpl implements IPointService{

    @Autowired
    private PointMapper pointMapper;


    @Override
    public void dailyUpdate(Point point) {
        pointMapper.dailyUpdate(point);
    }

    @Override
    public Integer getIntegral(Long id) {
        return pointMapper.selectIntegral(id);
    }

    @Override
    public void seriesUpdate(Point point) {
        pointMapper.seriesUpdate(point);
    }

    @Override
    public void updateIntegralByUserId(Long userId, Integer integral) {
        pointMapper.updateIntegralByUserId(userId,integral);
    }
}
